package com.block.common.service;


import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * 
 */
public class LogFactory {

    public  static Logger getErrorInfoLog()
    {
        return getLogByName("errorinfo");
    }
    public static Logger getAppReq()
    {
        return getLogByName("appreq");
    }
    public static Logger getCommLog(){
        return getLogByName("common");
   }
    public static Logger getPushLog() {
        return getLogByName("pushlog");
    }
    public static Logger getTimeLog() {
        return getLogByName("timelog");
    }
    public static Logger getAccountLog() {
        return getLogByName("accountlog");
    }
    public static Logger getMerchantLog() {
        return getLogByName("merchantlog");
    }
    public static Logger getUnionLog() {
        return getLogByName("unionlog");
    }
    public static Logger getJobLog() {
        return getLogByName("joblog");
    }
    public static Logger getNoticeMerLog() {
        return getLogByName("noticemerlog");
    }
    public static Logger getProductUniLog() {
        return getLogByName("productunilog");
    }
    public static Logger getProductLog() {
        return getLogByName("productlog");
    }
    public static Logger getSourceLog() {
        return getLogByName("sourcelog");
    }
    public static Logger getMqLog() {
        return getLogByName("mqlog");
    }

    /**
     * 根据名称查询日志对象。
     * @param name
     * @return
     */
    public static Logger getLogByName(String name)
    {
      return   LoggerFactory.getLogger(name);
    }


    /**
     * 获取日志对象。
     * @param clazz
     * @return
     */
    public static Logger getLog(Class clazz)
    {
        return LoggerFactory.getLogger(clazz);
    }


}
